package com.spark.lola.logistics.mapper;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.spark.lola.logistics.entity.LocationInfo;
import com.spark.lola.support.mybatis.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author: Zhi-peng wang
 * @date: 2020/04/26 16:10
 * 货运单常用地址信息mapper
 **/
@Mapper
public interface LocationInfoMapper extends BaseMapper<LocationInfo> {

    IPage<LocationInfo> findPage(Page<LocationInfo> page, @Param(Constants.WRAPPER) Wrapper<LocationInfo> wrapper);

    List<Long> getIdsByLeaderId(@Param("leaderId") Long leaderId);

    List<Long> getIdsByPurchaseId(@Param("purchaseId") Long purchaseId);

    List<Long> getIdsByCashierId(@Param("cashierId") Long cashierId);
}
